<?php

/*

RaNDoM $pointsVar (random_$pointsVar.php)

*/

$rank_check = 1;
$page_title = "RaNDoM $pointsVar";
include "header.inc.php";

$limit1 = 21600;
$timeLimit = "6 Hours";
if ($getInfo[premium] == 1) { $limit1 = 10800; $timeLimit = "3 Hours"; }

// Start Check

$checking = "random_points";
$limit = $timestamp - $limit1;

$findCheck = fetch("SELECT * FROM checking2 WHERE userid = '$userid' AND check_what = '$checking' AND timestamp > '$limit' AND game = '$game'");

// End Check

print "$openHTML";

print "<p>Welcome to RaNDoM $pointsVar! Here you can come play and get any where from 0 - 500 $pointsVar for free! You can only play every $timeLimit though!</p>";

if ($findCheck[id])
{
	echo "<p align=center><font color=red><b>You cannot play right now!</b></font></p><p align=center>(<a href=games.php?game=$game>back to games</A>)</p>";
}

if (!$findCheck[id])
{
	echo "<p align=center><font color=green><b><a href=random_ohms.pro.php?game=$game>Click here to play RaNDoM $pointsVar!</A></b></font></p><p align=center>(<a href=games.php?game=$game>back to games</A>)</p>";
}

print "$closeHTML";
?>